﻿using GalaSoft.MvvmLight;
using NaireSystem.ViewModels;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Controls;

namespace NaireSystem.ViewModels
{
    public class ViewModelDictManager : VMBase
    {

        private string _DictType;
        public string DictType { get => _DictType; set => Set("DictType", ref _DictType, value); }

        private string _DictName;
        public string DictName { get => _DictName; set => Set("DictName", ref _DictName, value); }


        private DictTypeModel _SelectedDictType;
        public DictTypeModel SelectedDictType { get => _SelectedDictType; set => Set("SelectedDictType", ref _SelectedDictType, value); }


        private ObservableCollection<DictTypeModel> _ListDictType = new ObservableCollection<DictTypeModel>();
        public ObservableCollection<DictTypeModel> ListDictType { get { return _ListDictType; } set { Set("ListDictType", ref _ListDictType, value); } }

        private DictDataModel _SelectedDictData;
        public DictDataModel SelectedDictData { get => _SelectedDictData; set => Set("SelectedDictData", ref _SelectedDictData, value); }



        private ObservableCollection<DictDataModel> _ListDictData = new ObservableCollection<DictDataModel>();
        public ObservableCollection<DictDataModel> ListDictData { get { return _ListDictData; } set { Set("ListDictData", ref _ListDictData, value); } }


    }
    public class DictModel : VMBase
    {
        private string _DictKey;
        public string DictKey { get => _DictKey; set => Set("DictKey", ref _DictKey, value); }

        private string _DictName;
        public string DictName { get => _DictName; set => Set("DictName", ref _DictName, value); }

        private string _DictValue;
        public string DictValue { get => _DictValue; set => Set("DictValue", ref _DictValue, value); }

        private ObservableCollection<DictTypeModel> _ListDictType = new ObservableCollection<DictTypeModel>();
        public ObservableCollection<DictTypeModel> ListDictType { get { return _ListDictType; } set { Set("ListDictType", ref _ListDictType, value); } }



    }

    public class DictTypeModel : VMBase
    {
        private string _DictName;
        public string DictName { get => _DictName; set => Set("DictName", ref _DictName, value); }

        private string _DictType;
        public string DictType { get => _DictType; set => Set("DictType", ref _DictType, value); }

        private string _CreateTime;
        public string CreateTime { get => _CreateTime; set => Set("CreateTime", ref _CreateTime, value); }

        private string _CreatorName;
        internal int id;

        public string CreatorName { get => _CreatorName; set => Set("CreatorName", ref _CreatorName, value); }


    }

    public class DictDataModel : VMBase
    {
        private string _CreateTime;
        public string CreateTime { get => _CreateTime; set => Set("CreateTime", ref _CreateTime, value); }

        private string _CreatorName;
        public string CreatorName { get => _CreatorName; set => Set("CreatorName", ref _CreatorName, value); }

        private int _DictValue;
        public int DictValue { get => _DictValue; set => Set("DictValue", ref _DictValue, value); }

        private string _DictLabel;
        internal string dict_type;
        internal int dict_data_id;

        public string DictLabel { get => _DictLabel; set => Set("DictLabel", ref _DictLabel, value); }






    }

}

